package com.ruibang.glass.produce.controller.tr;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.ruibang.glass.produce.domain.req.RackChangeLogReq;
import com.ruibang.glass.produce.entity.RackChangeLog;
import com.ruibang.glass.produce.service.RackChangeLogService;
import com.teaming.cloud.framework2.common.model.ResultBody;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @Author: songJinKang
 * @CreateTime: 2024-01-31  16:08
 * @Description: TODO:A型架更换日志控制器
 * @Version: 1.0
 */
@Api(tags = "A型架更换日志控制器")
@RestController
@RequestMapping("/api/glass/produce/tr/rackChangeLog")
public class RackChangeLogController {

    @Autowired
    private RackChangeLogService rackChangeLogService;

    @PostMapping("/queryBz")
    @ApiOperation(value = "查询包装A型架更换日志信息", response = ResultBody.class)
    public ResultBody<Page<RackChangeLog>> queryBz(@RequestBody RackChangeLogReq rackChangeLogReq) {
        return ResultBody.success(rackChangeLogService.queryBz(rackChangeLogReq));
    }

    @PostMapping("/queryTz")
    @ApiOperation(value = "查询投入A型架更换日志信息", response = ResultBody.class)
    public ResultBody<Page<RackChangeLog>> queryTz(@RequestBody RackChangeLogReq rackChangeLogReq) {
        return ResultBody.success(rackChangeLogService.queryTr(rackChangeLogReq));
    }
}
